package com.baicun.wish.utils.driver;

import org.openqa.selenium.chrome.ChromeDriver;

import java.util.Objects;

/**
 * @author baicun
 * @description WebDriverUtil工具类 打开ChromeDriver
 */
public class WebDriverUtil {

    private static final ChromeDriver CHROME_DRIVER = new ChromeDriver();

    static {

        //设置webdriver路径 加载驱动
        System.setProperty("webdriver.chrome.driver","src/main/java/com/baicun/wish/utils/driver/chromedriver.exe");

    }

    //selenium 开启ChromeDriver()驱动

    public static ChromeDriver openChrome(){
        return CHROME_DRIVER;
    }

}
